<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>

<%
  out.clear();
  String tblWidth="950px";
%><!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>	
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>客户导入</title>
<link href="/_resources/css/default/style.css" type="text/css" rel="stylesheet">
<link rel="stylesheet" type="text/css" href="/_resources/easyui/themes/default/easyui.css">
<link rel="stylesheet" type="text/css" href="/_resources/easyui/themes/icon.css">
<link rel="stylesheet" type="text/css" href="/_resources/easyui/demo/demo.css">
<script type="text/javascript" src="/_resources/easyui/jquery.min.js"></script>
<script type="text/javascript" src="/_resources/easyui/jquery.easyui.min.js"></script>
<script type="text/javascript" src="/_resources/js/jqueryUtils.js"></script>
<script language='javascript'>
	function jsImport(){
		if($('#file').val() ==''){
			alert('请选择导入文件');
			return;
		}
		var fileName = $('#file').val();
		if( $('#importForm').find("input[name=savingFlag]").val() ==1){
			alert('请不要重复点击');
			return;
		}
		
		$('#importForm').find("input[name=savingFlag]").val(1);
		$('#importForm').submit();
	}
</script>
</head>
<body >
<form id='importForm' action="doImport.do" method="post" enctype="multipart/form-data"> 
<input type='hidden' name='savingFlag' value="" /> <!-- 是否正在保存 -->
<table>
	<tr>
		<td	style='text-align:right'>导入文件</td>
		<td colspan='3'><input type="file" name="file" id="file"/>(excel文件)</td>
	</tr>
	<c:if test="${count != null}">
	<tr>
		<td></td>
		<td colspan='3'>
			导入：${count}条;<br>
			导入信息:
			${msg}
		</td>
	</tr>
	</c:if>
	<tr>
		<td></td>
		<td>
			<input type="button" value="导入" onclick='jsImport()'/>
			<b>${msg}</b>
		</td>
	</tr>
</table>			
</form>  
</body>  
</body>
</html>